inherited fmAddAgreements: TfmAddAgreements
  Left = 450
  Top = 165
  Width = 1014
  Height = 780
  Align = alCustom
  Caption = #1044#1086#1075#1086#1074#1086#1088
  Constraints.MinHeight = 780
  Constraints.MinWidth = 1014
  OnShow = FormShow
  PixelsPerInch = 96
  TextHeight = 13
  inherited sbBottom: TStatusBar
    Top = 726
    Width = 1006
  end
  inherited Panel1: TPanel
    Width = 1006
    Height = 33
    inherited BitBtn1: TBitBtn
      Left = 824
      Top = 6
    end
    inherited BitBtn2: TBitBtn
      Left = 908
      Top = 6
    end
  end
  object Panel5: TPanel [2]
    Left = 0
    Top = 33
    Width = 417
    Height = 693
    Align = alLeft
    TabOrder = 2
    object Label2: TLabel
      Left = 10
      Top = 98
      Width = 82
      Height = 13
      Caption = #1053#1086#1084#1077#1088' '#1076#1086#1075#1086#1074#1086#1088#1072
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clGray
      Font.Height = -11
      Font.Name = 'Tahoma'
      Font.Style = []
      ParentFont = False
    end
    object Label3: TLabel
      Left = 144
      Top = 146
      Width = 83
      Height = 13
      Caption = #1060#1086#1088#1084#1072' '#1076#1086#1075#1086#1074#1086#1088#1072
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clGray
      Font.Height = -11
      Font.Name = 'Tahoma'
      Font.Style = []
      ParentFont = False
      Visible = False
    end
    object Label18: TLabel
      Left = 8
      Top = 57
      Width = 92
      Height = 13
      Caption = #1055#1086#1083#1091#1095#1072#1090#1077#1083#1100' '#1091#1089#1083#1091#1075
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clGray
      Font.Height = -11
      Font.Name = 'Tahoma'
      Font.Style = []
      ParentFont = False
    end
    object Label4: TLabel
      Left = 16
      Top = 410
      Width = 123
      Height = 13
      Caption = #1044#1072#1090#1072' '#1074#1089#1090#1091#1087#1083#1077#1085#1080#1103' '#1074' '#1089#1080#1083#1091
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clGray
      Font.Height = -11
      Font.Name = 'Tahoma'
      Font.Style = []
      ParentFont = False
    end
    object Label32: TLabel
      Left = 20
      Top = 458
      Width = 127
      Height = 13
      Align = alCustom
      Caption = #1050#1086#1084#1084#1077#1085#1090#1072#1088#1080#1081' '#1082' '#1076#1086#1075#1086#1074#1086#1088#1091
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clGray
      Font.Height = -11
      Font.Name = 'Tahoma'
      Font.Style = []
      ParentFont = False
    end
    object Label8: TLabel
      Left = 288
      Top = 409
      Width = 90
      Height = 13
      Caption = #1044#1072#1090#1072' '#1079#1072#1074#1077#1088#1096#1077#1085#1080#1103
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clGray
      Font.Height = -11
      Font.Name = 'Tahoma'
      Font.Style = []
      ParentFont = False
    end
    object Label6: TLabel
      Left = 10
      Top = 149
      Width = 80
      Height = 13
      Caption = #1044#1072#1090#1072' '#1088#1086#1078#1076#1077#1085#1080#1103
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clGray
      Font.Height = -11
      Font.Name = 'Tahoma'
      Font.Style = []
      ParentFont = False
    end
    object Label1: TLabel
      Left = 16
      Top = 654
      Width = 154
      Height = 13
      Caption = #1044#1072#1090#1072' '#1087#1088#1077#1078#1076#1077#1074#1088'. '#1088#1072#1089#1090#1086#1088#1078#1077#1085#1080#1103
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clGray
      Font.Height = -11
      Font.Name = 'Tahoma'
      Font.Style = []
      ParentFont = False
    end
    object Label5: TLabel
      Left = 16
      Top = 713
      Width = 113
      Height = 13
      Align = alCustom
      Caption = #1055#1088#1080#1095#1080#1085#1072' '#1088#1072#1089#1090#1086#1088#1078#1077#1085#1080#1103
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clGray
      Font.Height = -11
      Font.Name = 'Tahoma'
      Font.Style = []
      ParentFont = False
    end
    object edAGNUM_N: TDBEdit
      Left = 8
      Top = 115
      Width = 127
      Height = 27
      TabStop = False
      Color = clMoneyGreen
      DataField = 'AGNUM_N'
      DataSource = dlgDS
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clBlack
      Font.Height = -16
      Font.Name = 'Tahoma'
      Font.Style = [fsBold]
      ParentFont = False
      ReadOnly = True
      TabOrder = 0
    end
    object edAGNUM: TDBEdit
      Left = 11
      Top = 217
      Width = 126
      Height = 27
      DataField = 'AGNUM'
      DataSource = dlgDS
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clBlack
      Font.Height = -16
      Font.Name = 'Tahoma'
      Font.Style = [fsBold]
      ParentFont = False
      TabOrder = 6
    end
    object GroupBox4: TGroupBox
      Left = 21
      Top = 245
      Width = 377
      Height = 163
      Caption = #1055#1086#1076#1087#1080#1089#1072#1083#1080' '#1076#1086#1075#1086#1074#1086#1088
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clGray
      Font.Height = -11
      Font.Name = 'Tahoma'
      Font.Style = []
      ParentFont = False
      TabOrder = 2
      TabStop = True
      object ToolBar2: TToolBar
        Left = 2
        Top = 15
        Width = 79
        Height = 34
        Align = alCustom
        AutoSize = True
        BorderWidth = 2
        EdgeInner = esNone
        EdgeOuter = esNone
        Images = DMInv.ilActive
        TabOrder = 0
        TabStop = True
        Transparent = True
        object ToolButton4: TToolButton
          Left = 0
          Top = 2
          Hint = #1044#1086#1073#1072#1074#1080#1090#1100'/'#1056#1077#1076#1072#1082#1090#1080#1088#1086#1074#1072#1090#1100
          ImageIndex = 30
          ParentShowHint = False
          ShowHint = True
          OnClick = ToolButton4Click
        end
        object ToolButton5: TToolButton
          Left = 23
          Top = 2
          Hint = #1059#1076#1072#1083#1080#1090#1100
          ImageIndex = 29
          ParentShowHint = False
          ShowHint = True
          OnClick = ToolButton5Click
        end
        object ToolButton6: TToolButton
          Left = 46
          Top = 2
          Caption = 'ToolButton6'
          ImageIndex = 2
          Visible = False
          OnClick = ToolButton6Click
        end
      end
      object cxGrid2: TcxGrid
        Left = 2
        Top = 56
        Width = 373
        Height = 105
        Align = alCustom
        TabOrder = 1
        LookAndFeel.Kind = lfStandard
        object cxGridDBTableView2: TcxGridDBTableView
          NavigatorButtons.ConfirmDelete = False
          NavigatorButtons.First.Visible = True
          NavigatorButtons.PriorPage.Visible = True
          NavigatorButtons.Prior.Visible = True
          NavigatorButtons.Next.Visible = True
          NavigatorButtons.NextPage.Visible = True
          NavigatorButtons.Last.Visible = True
          NavigatorButtons.Insert.Visible = False
          NavigatorButtons.Append.Visible = False
          NavigatorButtons.Delete.Visible = False
          NavigatorButtons.Edit.Visible = False
          NavigatorButtons.Post.Visible = False
          NavigatorButtons.Cancel.Visible = False
          NavigatorButtons.Refresh.Visible = False
          NavigatorButtons.SaveBookmark.Visible = False
          NavigatorButtons.GotoBookmark.Visible = False
          NavigatorButtons.Filter.Visible = False
          FilterBox.Visible = fvNever
          DataController.DataSource = dsAPodpisant
          DataController.Summary.DefaultGroupSummaryItems = <>
          DataController.Summary.FooterSummaryItems = <>
          DataController.Summary.SummaryGroups = <>
          OptionsBehavior.CellHints = True
          OptionsBehavior.ImmediateEditor = False
          OptionsBehavior.IncSearch = True
          OptionsCustomize.ColumnFiltering = False
          OptionsData.Deleting = False
          OptionsData.Editing = False
          OptionsData.Inserting = False
          OptionsView.NavigatorOffset = 10
          OptionsView.CellAutoHeight = True
          OptionsView.ColumnAutoWidth = True
          OptionsView.GroupByBox = False
          OptionsView.Indicator = True
          OptionsView.ShowColumnFilterButtons = sfbAlways
          Preview.Visible = True
          Styles.IncSearch = DMInv.cxKrasniyText
          Styles.Selection = DMInv.cxJoltiyFon
          Styles.Header = DMInv.cxSiniyText
          object cxGridDBTableView2FIO: TcxGridDBColumn
            Caption = #1060#1048#1054
            DataBinding.FieldName = 'FIO'
            Width = 250
          end
          object cxGridDBTableView2SDNAME: TcxGridDBColumn
            Caption = #1057#1074#1103#1079#1100' '#1089' '#1087#1086#1083#1091#1095'.'
            DataBinding.FieldName = 'SDNAME'
            Width = 107
          end
        end
        object cxGridLevel3: TcxGridLevel
          GridView = cxGridDBTableView2
        end
      end
      object RadioGroup1: TRadioGroup
        Left = 122
        Top = 11
        Width = 183
        Height = 32
        Columns = 2
        ItemIndex = 0
        Items.Strings = (
          #1060#1080#1079'. '#1083#1080#1094#1086
          #1070#1088'. '#1083#1080#1094#1086)
        TabOrder = 2
      end
    end
    object edAGDATEEND: TcxDBDateEdit
      Left = 288
      Top = 426
      DataBinding.DataField = 'AGDATEEND'
      DataBinding.DataSource = dlgDS
      ParentFont = False
      Properties.DateButtons = [btnClear, btnToday]
      Properties.InputKind = ikMask
      Properties.SaveTime = False
      Properties.ShowTime = False
      Properties.WeekNumbers = True
      Properties.OnValidate = edAGDATEENDPropertiesValidate
      Style.Font.Charset = DEFAULT_CHARSET
      Style.Font.Color = clWindowText
      Style.Font.Height = -16
      Style.Font.Name = 'Tahoma'
      Style.Font.Style = [fsBold]
      Style.IsFontAssigned = True
      TabOrder = 4
      Width = 121
    end
    object mdAGNOTE: TDBMemo
      Left = 18
      Top = 472
      Width = 391
      Height = 169
      Align = alCustom
      DataField = 'AGNOTE'
      DataSource = dlgDS
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clBlack
      Font.Height = -13
      Font.Name = 'Tahoma'
      Font.Style = [fsBold]
      ParentFont = False
      TabOrder = 5
    end
    object cxCheckBox3: TcxCheckBox
      Left = 8
      Top = 193
      Caption = #8470' '#1076#1086#1075'. '#1085#1072' '#1076#1086#1082#1091#1084#1077#1085#1090#1077
      ParentFont = False
      Properties.OnChange = cxCheckBox3PropertiesChange
      Style.Font.Charset = DEFAULT_CHARSET
      Style.Font.Color = clGray
      Style.Font.Height = -13
      Style.Font.Name = 'Tahoma'
      Style.Font.Style = []
      Style.IsFontAssigned = True
      TabOrder = 1
      Width = 149
    end
    object cxDBImage1: TcxDBImage
      Left = 272
      Top = 102
      DataBinding.DataField = 'PPIMAGE'
      DataBinding.DataSource = dsPhoto
      Properties.GraphicClassName = 'TJPEGImage'
      TabOrder = 7
      Height = 139
      Width = 137
    end
    object edRes_Fio: TcxDBButtonEdit
      Left = 144
      Top = 111
      DataBinding.DataField = 'FIO'
      ParentFont = False
      Properties.Buttons = <
        item
          Default = True
        end>
      Properties.MaxLength = 0
      Properties.ReadOnly = True
      Properties.OnButtonClick = edRes_FioPropertiesButtonClick
      Style.Font.Charset = DEFAULT_CHARSET
      Style.Font.Color = clWindowText
      Style.Font.Height = -13
      Style.Font.Name = 'Tahoma'
      Style.Font.Style = []
      Style.IsFontAssigned = True
      TabOrder = 8
      Visible = False
      Width = 261
    end
    object eNAME: TcxDBButtonEdit
      Left = 145
      Top = 161
      DataBinding.DataField = 'FORMA'
      DataBinding.DataSource = dlgDS
      Properties.Buttons = <
        item
          Default = True
        end>
      Properties.MaxLength = 0
      Properties.ReadOnly = True
      Properties.OnButtonClick = eNAMEPropertiesButtonClick
      TabOrder = 9
      Visible = False
      Width = 126
    end
    object cxDBTextEdit1: TcxDBTextEdit
      Left = 9
      Top = 167
      TabStop = False
      DataBinding.DataField = 'PDATEBIRTH'
      DataBinding.DataSource = dsPoluchUslug
      Properties.ReadOnly = True
      Style.Color = clMoneyGreen
      TabOrder = 10
      Width = 108
    end
    object rgPodr: TcxDBRadioGroup
      Left = 8
      Top = 2
      Caption = #1055#1086#1076#1088#1072#1079#1076#1077#1083#1077#1085#1080#1077
      DataBinding.DataField = 'AGPODRTYPE'
      DataBinding.DataSource = dlgDS
      ParentFont = False
      Properties.Columns = 5
      Properties.Items = <
        item
          Caption = #1044'/'#1089
          Value = 0
        end
        item
          Caption = #1053#1072#1095'. '#1075#1080#1084#1085'.'
          Value = 1
        end
        item
          Caption = #1057#1088#1077#1076#1085'. '#1096#1082'.'
          Value = 2
        end
        item
          Caption = #1057#1090#1072#1088#1096'. '#1096#1082'.'
          Value = 3
        end
        item
          Caption = #1051#1072#1075#1077#1088#1100
          Value = 4
        end>
      Style.Font.Charset = DEFAULT_CHARSET
      Style.Font.Color = clWindowText
      Style.Font.Height = -11
      Style.Font.Name = 'Tahoma'
      Style.Font.Style = []
      Style.IsFontAssigned = True
      TabOrder = 11
      Height = 49
      Width = 401
    end
    object edPoluch: TcxTextEdit
      Left = 8
      Top = 72
      TabStop = False
      ParentFont = False
      Style.Color = clMoneyGreen
      Style.Font.Charset = DEFAULT_CHARSET
      Style.Font.Color = clWindowText
      Style.Font.Height = -13
      Style.Font.Name = 'Tahoma'
      Style.Font.Style = [fsBold]
      Style.IsFontAssigned = True
      TabOrder = 12
      Text = 'edPoluch'
      Width = 401
    end
    object edAGDATEBEGIN: TcxDBDateEdit
      Left = 17
      Top = 426
      DataBinding.DataField = 'AGDATEBEGIN'
      DataBinding.DataSource = dlgDS
      ParentFont = False
      Properties.DateButtons = [btnClear, btnToday]
      Properties.InputKind = ikMask
      Properties.SaveTime = False
      Properties.ShowTime = False
      Properties.WeekNumbers = True
      Properties.OnEditValueChanged = cxDBDateEdit2PropertiesEditValueChanged
      Style.Font.Charset = DEFAULT_CHARSET
      Style.Font.Color = clWindowText
      Style.Font.Height = -16
      Style.Font.Name = 'Tahoma'
      Style.Font.Style = [fsBold]
      Style.IsFontAssigned = True
      TabOrder = 3
      Width = 121
    end
    object edDATECLOSE: TcxDBDateEdit
      Left = 16
      Top = 670
      DataBinding.DataField = 'AGDATECLOSE'
      DataBinding.DataSource = dlgDS
      ParentFont = False
      Properties.DateButtons = [btnClear, btnToday]
      Properties.InputKind = ikMask
      Properties.SaveTime = False
      Properties.ShowTime = False
      Properties.WeekNumbers = True
      Style.Font.Charset = DEFAULT_CHARSET
      Style.Font.Color = clWindowText
      Style.Font.Height = -16
      Style.Font.Name = 'Tahoma'
      Style.Font.Style = [fsBold]
      Style.IsFontAssigned = True
      TabOrder = 13
      Width = 137
    end
    object mdAGNOTECLOSE: TDBMemo
      Left = 16
      Top = 729
      Width = 393
      Height = 51
      Align = alCustom
      DataField = 'AGNOTECLOSE'
      DataSource = dlgDS
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clBlack
      Font.Height = -13
      Font.Name = 'Tahoma'
      Font.Style = [fsBold]
      ParentFont = False
      TabOrder = 14
    end
    object Panel4: TPanel
      Left = 256
      Top = 656
      Width = 153
      Height = 57
      Color = clSkyBlue
      TabOrder = 15
      Visible = False
      object Label21: TLabel
        Left = 8
        Top = 4
        Width = 93
        Height = 13
        Caption = #1044#1072#1090#1072' '#1088#1077#1075#1080#1089#1090#1088#1072#1094#1080#1080
        Font.Charset = DEFAULT_CHARSET
        Font.Color = clGray
        Font.Height = -11
        Font.Name = 'Tahoma'
        Font.Style = []
        ParentFont = False
      end
      object cxDBDateEdit1: TcxDBDateEdit
        Left = 8
        Top = 22
        DataBinding.DataField = 'AGDATEREGISTER'
        DataBinding.DataSource = dlgDS
        ParentFont = False
        Properties.DateButtons = [btnClear, btnToday]
        Properties.InputKind = ikMask
        Properties.SaveTime = False
        Properties.ShowTime = False
        Properties.WeekNumbers = True
        Style.Font.Charset = DEFAULT_CHARSET
        Style.Font.Color = clWindowText
        Style.Font.Height = -16
        Style.Font.Name = 'Tahoma'
        Style.Font.Style = [fsBold]
        Style.IsFontAssigned = True
        TabOrder = 0
        OnClick = cxDBDateEdit1Click
        Width = 137
      end
    end
    object GroupBox2: TGroupBox
      Left = 17
      Top = 478
      Width = 392
      Height = 72
      Caption = #1055#1086#1089#1090#1086#1103#1085#1085#1099#1081' '#1072#1076#1088#1077#1089' '#1087#1086#1083#1091#1095#1072#1090#1077#1083#1103' '#1091#1089#1083#1091#1075
      TabOrder = 16
      Visible = False
      object mAdress: TcxDBMemo
        Left = 2
        Top = 15
        Align = alClient
        DataBinding.DataField = 'CIVALUE'
        DataBinding.DataSource = dsContInfo
        ParentFont = False
        Style.Font.Charset = DEFAULT_CHARSET
        Style.Font.Color = clWindowText
        Style.Font.Height = -16
        Style.Font.Name = 'Tahoma'
        Style.Font.Style = []
        Style.IsFontAssigned = True
        TabOrder = 0
        Height = 55
        Width = 388
      end
    end
  end
  object Panel2: TPanel [3]
    Left = 425
    Top = 33
    Width = 581
    Height = 693
    Align = alClient
    TabOrder = 3
    object bFromFile: TcxButton
      Left = 1
      Top = 1
      Width = 579
      Height = 25
      Caption = #1044#1086#1073#1072#1074#1080#1090#1100'/'#1080#1079#1084#1077#1085#1080#1090#1100
      Font.Charset = DEFAULT_CHARSET
      Font.Color = clWindowText
      Font.Height = -13
      Font.Name = 'Tahoma'
      Font.Style = [fsBold]
      ParentFont = False
      TabOrder = 0
      OnClick = bFromFileClick
      Align = alTop
      Glyph.Data = {
        76010000424D7601000000000000760000002800000020000000100000000100
        04000000000000010000CE0E0000D80E00001000000000000000000000000000
        80000080000000808000800000008000800080800000C0C0C000808080000000
        FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF00333333333333
        3333333333387F3333333333333333333333333333387F333333333333344333
        3333333333387F3333333333333443333333333333387F333333333333344333
        3333333333387F3333333333333443333333333333387F333333333333344333
        3333387FFFFFFFFFFFFF3344444444444433387777777F777777334444444444
        4433388888887F8888883333333443333333333333387F333333333333344333
        3333333333387F3333333333333443333333333333387F333333333333344333
        3333333333387F33333333333334433333333333333877333333333333333333
        3333333333388833333333333333333333333333333333333333}
      NumGlyphs = 2
    end
    object PdfViewer1: TPdfViewer
      Left = 1
      Top = 26
      Width = 579
      Height = 666
      Align = alClient
      About = 'Synactis PDF Viewer version 1.0'
      AutoOpen = True
      Copies = 1
      EndPage = 0
      FitMode = vmFitBoxHorz
      LayoutMode = lmDontCare
      PageMode = pmStandard
      ShowPrintDialog = True
      ShowScrollBars = True
      ShowToolBar = True
      ShrinkToMargins = True
      StartPage = 1
    end
  end
  object bScan: TcxButton [4]
    Left = 1020
    Top = 765
    Width = 113
    Height = 25
    Caption = #1057#1082#1072#1085#1080#1088#1086#1074#1072#1090#1100
    Font.Charset = DEFAULT_CHARSET
    Font.Color = clWindowText
    Font.Height = -13
    Font.Name = 'Tahoma'
    Font.Style = [fsBold]
    ParentFont = False
    TabOrder = 4
    Visible = False
    OnClick = bScanClick
    Glyph.Data = {
      76010000424D7601000000000000760000002800000020000000100000000100
      04000000000000010000130B0000130B00001000000000000000000000000000
      800000800000008080008000000080008000808000007F7F7F00BFBFBF000000
      FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF0033333333B333
      333B33FF33337F3333F73BB3777BB7777BB3377FFFF77FFFF77333B000000000
      0B3333777777777777333330FFFFFFFF07333337F33333337F333330FFFFFFFF
      07333337F33333337F333330FFFFFFFF07333337F33333337F333330FFFFFFFF
      07333FF7F33333337FFFBBB0FFFFFFFF0BB37777F3333333777F3BB0FFFFFFFF
      0BBB3777F3333FFF77773330FFFF000003333337F333777773333330FFFF0FF0
      33333337F3337F37F3333330FFFF0F0B33333337F3337F77FF333330FFFF003B
      B3333337FFFF77377FF333B000000333BB33337777777F3377FF3BB3333BB333
      3BB33773333773333773B333333B3333333B7333333733333337}
    NumGlyphs = 2
  end
  object bDel: TcxButton [5]
    Left = 1150
    Top = 765
    Width = 104
    Height = 25
    Caption = #1059#1076#1072#1083#1080#1090#1100
    Font.Charset = DEFAULT_CHARSET
    Font.Color = clWindowText
    Font.Height = -13
    Font.Name = 'Tahoma'
    Font.Style = [fsBold]
    ParentFont = False
    TabOrder = 5
    Visible = False
    OnClick = bDelClick
    Glyph.Data = {
      76010000424D7601000000000000760000002800000020000000100000000100
      0400000000000001000000000000000000001000000000000000000000000000
      8000008000000080800080000000800080008080000080808000C0C0C0000000
      FF0000FF000000FFFF00FF000000FF00FF00FFFF0000FFFFFF00333333333333
      3333333333333333333333333333333333333333333333333333333333333333
      3333333333333333333333337333333333333333F33333333333333313333333
      333333337F33333333333333113333713333333377F33377F333333371733717
      3333333377F3377F333333333117311333333333377F377F3333333337111133
      33333333337777F33333333337111333333333333F777F333333333371111733
      3333333337777F3333333333117311733333333377F377F33333333333333117
      333333333333377F33333333333333117333333333333377F333333333333333
      3333333333333333333333333333333333333333333333333333}
    NumGlyphs = 2
  end
  object cxSplitter1: TcxSplitter [6]
    Left = 417
    Top = 33
    Width = 8
    Height = 693
    Control = Panel5
  end
  inherited dlgDS: TDataSource
    Left = 472
    Top = 64
  end
  object odScan: TOpenDialog
    Filter = 'PDF|*.pdf'
    InitialDir = 'c:\'
    Left = 488
    Top = 320
  end
  object qA_Scan: TIBQuery
    Database = DMInv.DBRead
    Transaction = DMInv.IBTransaction1
    AfterInsert = qA_ScanAfterInsert
    CachedUpdates = True
    DataSource = dlgDS
    SQL.Strings = (
      'SELECT S.*'
      'FROM A_SCAN S'
      'WHERE S.AGID = :AGID')
    UpdateObject = quA_Scan
    GeneratorField.Field = 'ASID'
    GeneratorField.Generator = 'GEN_A_SCAN'
    Left = 475
    Top = 360
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'AGID'
        ParamType = ptUnknown
      end>
    object qA_ScanASID: TIntegerField
      FieldName = 'ASID'
      Origin = '"A_SCAN"."ASID"'
      ProviderFlags = [pfInUpdate, pfInWhere, pfInKey]
      Required = True
    end
    object qA_ScanAGID: TIntegerField
      FieldName = 'AGID'
      Origin = '"A_SCAN"."AGID"'
      Required = True
    end
    object qA_ScanASIMAGE: TBlobField
      FieldName = 'ASIMAGE'
      Origin = '"A_SCAN"."ASIMAGE"'
      ProviderFlags = [pfInUpdate]
      Size = 8
    end
    object qA_ScanASNOTE: TIBStringField
      FieldName = 'ASNOTE'
      Origin = '"A_SCAN"."ASNOTE"'
      Size = 255
    end
    object qA_ScanASUSERENTER: TIBStringField
      FieldName = 'ASUSERENTER'
      Origin = '"A_SCAN"."ASUSERENTER"'
      Size = 40
    end
    object qA_ScanASTIMEENTER: TDateTimeField
      FieldName = 'ASTIMEENTER'
      Origin = '"A_SCAN"."ASTIMEENTER"'
    end
    object qA_ScanASUSEREDIT: TIBStringField
      FieldName = 'ASUSEREDIT'
      Origin = '"A_SCAN"."ASUSEREDIT"'
      Size = 40
    end
    object qA_ScanASTIMEEDIT: TDateTimeField
      FieldName = 'ASTIMEEDIT'
      Origin = '"A_SCAN"."ASTIMEEDIT"'
    end
  end
  object quA_Scan: TIBUpdateSQL
    RefreshSQL.Strings = (
      'Select '
      '  ASID,'
      '  AGID,'
      '  ASIMAGE,'
      '  ASNOTE,'
      '  ASUSERENTER,'
      '  ASTIMEENTER,'
      '  ASUSEREDIT,'
      '  ASTIMEEDIT'
      'from A_SCAN '
      'where'
      '  ASID = :ASID')
    ModifySQL.Strings = (
      'update A_SCAN'
      'set'
      '  AGID = :AGID,'
      '  ASID = :ASID,'
      '  ASIMAGE = :ASIMAGE,'
      '  ASNOTE = :ASNOTE,'
      '  ASTIMEEDIT = :ASTIMEEDIT,'
      '  ASTIMEENTER = :ASTIMEENTER,'
      '  ASUSEREDIT = :ASUSEREDIT,'
      '  ASUSERENTER = :ASUSERENTER'
      'where'
      '  ASID = :OLD_ASID')
    InsertSQL.Strings = (
      'insert into A_SCAN'
      
        '  (AGID, ASID, ASIMAGE, ASNOTE, ASTIMEEDIT, ASTIMEENTER, ASUSERE' +
        'DIT, ASUSERENTER)'
      'values'
      
        '  (:AGID, :ASID, :ASIMAGE, :ASNOTE, :ASTIMEEDIT, :ASTIMEENTER, :' +
        'ASUSEREDIT, '
      '   :ASUSERENTER)')
    DeleteSQL.Strings = (
      'delete from A_SCAN'
      'where'
      '  ASID = :OLD_ASID')
    Left = 507
    Top = 360
  end
  object dsAPodpisant: TDataSource
    DataSet = qAPodpisant
    Left = 456
    Top = 200
  end
  object qAPodpisant: TIBQuery
    Database = DMInv.DBRead
    Transaction = DMInv.IBTransaction1
    AfterInsert = qAPodpisantAfterInsert
    CachedUpdates = True
    DataSource = dlgDS
    SQL.Strings = (
      
        'select distinct AP.*, P.PDATEBIRTH, iif((P.PID is null), (coales' +
        'ce(JL.JLOPF, JLSD.SDNAME) || '#39#39#39#39' || JL.JLEGALNAME || '#39#39#39#39'), (P.' +
        'PLASTNAME||'#39' '#39'||substring(P.PNAME from 1 for 1 )||'#39'. '#39'||'
      
        '     coalesce(substring(P.PPATRONYMIC from 1 for 1)||'#39'.'#39','#39' '#39'))) ' +
        'as FIO, SD.SDNAME'
      'from AGR_PODPISANT AP'
      'left join PEOPLE P on (P.PID = AP.PID)'
      'left join JURLITSA JL on (JL.JLID = AP.ID_JURIDICAL_FACE)'
      'left join SYS_DIC JLSD on (JLSD.SDID = JL.JLOPFSDID)'
      'left join SYS_DIC SD on (SD.SDID = AP.POSTATUS)'
      'where (AP.AGID = :AGID)')
    UpdateObject = quAPodpisant
    Left = 488
    Top = 200
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'AGID'
        ParamType = ptUnknown
      end>
    object qAPodpisantID: TIntegerField
      FieldName = 'ID'
    end
    object qAPodpisantAGID: TIntegerField
      FieldName = 'AGID'
      Origin = '"AGR_PODPISANT"."AGID"'
      ProviderFlags = [pfInUpdate, pfInWhere, pfInKey]
      Required = True
    end
    object qAPodpisantPID: TIntegerField
      FieldName = 'PID'
      Origin = '"AGR_PODPISANT"."PID"'
      ProviderFlags = [pfInUpdate, pfInWhere, pfInKey]
    end
    object qAPodpisantID_JURIDICAL_FACE: TIntegerField
      FieldName = 'ID_JURIDICAL_FACE'
    end
    object qAPodpisantPOTYPE: TIntegerField
      FieldName = 'POTYPE'
      Origin = '"AGR_PODPISANT"."POTYPE"'
    end
    object qAPodpisantPOSTATUS: TIntegerField
      FieldName = 'POSTATUS'
      Origin = '"AGR_PODPISANT"."POSTATUS"'
    end
    object qAPodpisantPDATEBIRTH: TDateField
      FieldName = 'PDATEBIRTH'
      Origin = '"PEOPLE"."PDATEBIRTH"'
    end
    object qAPodpisantFIO: TIBStringField
      FieldName = 'FIO'
      ProviderFlags = []
      Size = 769
    end
    object qAPodpisantSDNAME: TIBStringField
      FieldName = 'SDNAME'
      Origin = '"SYS_DIC"."SDNAME"'
      Size = 255
    end
  end
  object quAPodpisant: TIBUpdateSQL
    RefreshSQL.Strings = (
      'Select '
      '  ID,'
      '  AGID,'
      '  PID,'
      '  POTYPE,'
      '  ID_JURIDICAL_FACE,'
      '  POSTATUS,'
      '  POUSERENTER,'
      '  POTIMEENTER,'
      '  POUSEREDIT,'
      '  POTIMEEDIT,'
      '  PDATEBIRTH,'
      '  FIO'
      'from AGR_PODPISANT '
      'where'
      '  AGID = :AGID and'
      '  PID = :PID')
    ModifySQL.Strings = (
      'update AGR_PODPISANT'
      'set'
      '  AGID = :AGID,'
      '  PID = :PID,'
      '  ID_JURIDICAL_FACE = :ID_JURIDICAL_FACE,'
      '  POSTATUS = :POSTATUS,'
      '  POTIMEEDIT = :POTIMEEDIT,'
      '  POTIMEENTER = :POTIMEENTER,'
      '  POTYPE = :POTYPE,'
      '  POUSEREDIT = :POUSEREDIT,'
      '  POUSERENTER = :POUSERENTER'
      'where'
      '  AGID = :OLD_AGID and'
      '  PID = :OLD_PID')
    InsertSQL.Strings = (
      'insert into AGR_PODPISANT'
      
        '  (ID, AGID, PID, ID_JURIDICAL_FACE, POSTATUS, POTIMEEDIT, POTIM' +
        'EENTER, POTYPE, POUSEREDIT, '
      '   POUSERENTER)'
      'values'
      
        '  (gen_id(GEN_AGR_PODPISANT, 1), :AGID, :PID, :ID_JURIDICAL_FACE' +
        ', :POSTATUS, :POTIMEEDIT, :POTIMEENTER, :POTYPE, '
      '   :POUSEREDIT, :POUSERENTER)')
    DeleteSQL.Strings = (
      'delete from AGR_PODPISANT'
      'where'
      '  AGID = :OLD_AGID and'
      '  PID = :OLD_PID')
    Left = 520
    Top = 200
  end
  object qPhoto: TIBQuery
    Database = DMInv.DBRead
    Transaction = DMInv.IBTransaction1
    DataSource = dsPoluchUslug
    SQL.Strings = (
      'SELECT PP.*'
      'from P_PHOTOS PP'
      'WHERE PP.PID = :pid')
    Left = 536
    Top = 488
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'pid'
        ParamType = ptUnknown
      end>
    object qPhotoPID: TIntegerField
      FieldName = 'PID'
      Origin = '"P_PHOTOS"."PID"'
      ProviderFlags = [pfInUpdate, pfInWhere, pfInKey]
      Required = True
    end
    object qPhotoPPIMAGE: TBlobField
      FieldName = 'PPIMAGE'
      Origin = '"P_PHOTOS"."PPIMAGE"'
      ProviderFlags = [pfInUpdate]
      Size = 8
    end
    object qPhotoPPNOTE: TIBStringField
      FieldName = 'PPNOTE'
      Origin = '"P_PHOTOS"."PPNOTE"'
      Size = 255
    end
    object qPhotoPPUSERENTER: TIBStringField
      FieldName = 'PPUSERENTER'
      Origin = '"P_PHOTOS"."PPUSERENTER"'
      Size = 40
    end
    object qPhotoPPTIMEENTER: TDateTimeField
      FieldName = 'PPTIMEENTER'
      Origin = '"P_PHOTOS"."PPTIMEENTER"'
    end
    object qPhotoPPUSEREDIT: TIBStringField
      FieldName = 'PPUSEREDIT'
      Origin = '"P_PHOTOS"."PPUSEREDIT"'
      Size = 40
    end
    object qPhotoPPTIMEEDIT: TDateTimeField
      FieldName = 'PPTIMEEDIT'
      Origin = '"P_PHOTOS"."PPTIMEEDIT"'
    end
  end
  object dsPhoto: TDataSource
    DataSet = qPhoto
    Left = 504
    Top = 488
  end
  object qChekRegistration: TIBQuery
    Database = DMInv.DBRead
    Transaction = DMInv.IBTransaction1
    SQL.Strings = (
      'SELECT U.URID'
      'FROM USERFORREGISTRATION U'
      'WHERE U.USERNAME = :guser')
    GeneratorField.Field = 'SCID'
    Left = 504
    Top = 536
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'guser'
        ParamType = ptUnknown
      end>
    object qChekRegistrationURID: TIntegerField
      FieldName = 'URID'
      Origin = '"USERFORREGISTRATION"."URID"'
      ProviderFlags = [pfInUpdate, pfInWhere, pfInKey]
      Required = True
    end
  end
  object qPoluchUslug: TIBQuery
    Database = DMInv.DBRead
    Transaction = DMInv.IBTransaction1
    AfterInsert = qPoluchUslugAfterInsert
    CachedUpdates = True
    DataSource = dlgDS
    SQL.Strings = (
      
        'SELECT APU.*, (P.PLASTNAME||'#39' '#39'||SUBSTRING(P.PNAME FROM 1 FOR 1 ' +
        ')||'#39'. '#39'||'
      
        '     COALESCE(SUBSTRING(P.PPATRONYMIC FROM 1 FOR 1)||'#39'.'#39','#39' '#39')) A' +
        'S fio, P.PDATEBIRTH'
      'FROM AGR_POLUCH_USLUG APU'
      'INNER JOIN PEOPLE P ON P.PID = APU.PID'
      'WHERE APU.AGID = :AGID')
    UpdateObject = quPoluchUslug
    Left = 488
    Top = 149
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'AGID'
        ParamType = ptUnknown
      end>
    object qPoluchUslugAGID: TIntegerField
      FieldName = 'AGID'
      Origin = '"AGR_POLUCH_USLUG"."AGID"'
      ProviderFlags = [pfInUpdate, pfInWhere, pfInKey]
      Required = True
    end
    object qPoluchUslugPID: TIntegerField
      FieldName = 'PID'
      Origin = '"AGR_POLUCH_USLUG"."PID"'
      Required = True
    end
    object qPoluchUslugPUUSERENTER: TIBStringField
      FieldName = 'PUUSERENTER'
      Origin = '"AGR_POLUCH_USLUG"."PUUSERENTER"'
      Size = 40
    end
    object qPoluchUslugPUTIMEENTER: TDateTimeField
      FieldName = 'PUTIMEENTER'
      Origin = '"AGR_POLUCH_USLUG"."PUTIMEENTER"'
    end
    object qPoluchUslugPUUSEREDIT: TIBStringField
      FieldName = 'PUUSEREDIT'
      Origin = '"AGR_POLUCH_USLUG"."PUUSEREDIT"'
      Size = 40
    end
    object qPoluchUslugPUTIMEEDIT: TDateTimeField
      FieldName = 'PUTIMEEDIT'
      Origin = '"AGR_POLUCH_USLUG"."PUTIMEEDIT"'
    end
    object qPoluchUslugFIO: TIBStringField
      FieldName = 'FIO'
      ProviderFlags = []
      Size = 769
    end
    object qPoluchUslugPDATEBIRTH: TDateField
      FieldName = 'PDATEBIRTH'
      Origin = '"PEOPLE"."PDATEBIRTH"'
    end
  end
  object quPoluchUslug: TIBUpdateSQL
    RefreshSQL.Strings = (
      'Select '
      '  AGID,'
      '  PID,'
      '  PUUSERENTER,'
      '  PUTIMEENTER,'
      '  PUUSEREDIT,'
      '  PUTIMEEDIT'
      'from AGR_POLUCH_USLUG '
      'where'
      '  AGID = :AGID and'
      '  PID = :PID')
    ModifySQL.Strings = (
      'update AGR_POLUCH_USLUG'
      'set'
      '  AGID = :AGID,'
      '  PID = :PID,'
      '  PUTIMEEDIT = :PUTIMEEDIT,'
      '  PUTIMEENTER = :PUTIMEENTER,'
      '  PUUSEREDIT = :PUUSEREDIT,'
      '  PUUSERENTER = :PUUSERENTER'
      'where'
      '  AGID = :OLD_AGID and'
      '  PID = :OLD_PID')
    InsertSQL.Strings = (
      'insert into AGR_POLUCH_USLUG'
      '  (AGID, PID, PUTIMEEDIT, PUTIMEENTER, PUUSEREDIT, PUUSERENTER)'
      'values'
      
        '  (:AGID, :PID, :PUTIMEEDIT, :PUTIMEENTER, :PUUSEREDIT, :PUUSERE' +
        'NTER)')
    DeleteSQL.Strings = (
      'delete from AGR_POLUCH_USLUG'
      'where'
      '  AGID = :OLD_AGID and'
      '  PID = :OLD_PID')
    Left = 520
    Top = 149
  end
  object dsPoluchUslug: TDataSource
    DataSet = qPoluchUslug
    Left = 456
    Top = 149
  end
  object quContInfo: TIBUpdateSQL
    RefreshSQL.Strings = (
      'Select '
      '  CIID,'
      '  PID,'
      '  CITYPE,'
      '  CIVALUE,'
      '  CINOTE,'
      '  CIUSERENTER,'
      '  CITIMEENTER,'
      '  CIUSEREDIT,'
      '  CITIMEEDIT,'
      '  SDNAME'
      'from CONTACTINFO '
      'where'
      '  CIID = :CIID')
    ModifySQL.Strings = (
      'update CONTACTINFO'
      'set'
      '  CINOTE = :CINOTE,'
      '  CITIMEEDIT = :CITIMEEDIT,'
      '  CITIMEENTER = :CITIMEENTER,'
      '  CIUSEREDIT = :CIUSEREDIT,'
      '  CIUSERENTER = :CIUSERENTER,'
      '  CIVALUE = :CIVALUE,'
      '  PID = :PID'
      'where'
      '  CIID = :OLD_CIID and CITYPE = 1153')
    InsertSQL.Strings = (
      'insert into CONTACTINFO'
      
        '  (CINOTE, CITIMEEDIT, CITIMEENTER, CITYPE, CIUSEREDIT, CIUSEREN' +
        'TER, CIVALUE, '
      '   PID, CIID)'
      'values'
      
        '  (:CINOTE, :CITIMEEDIT, :CITIMEENTER, :CITYPE, :CIUSEREDIT, :CI' +
        'USERENTER, '
      '   :CIVALUE, :PID, :CIID)')
    DeleteSQL.Strings = (
      'null;')
    Left = 504
    Top = 704
  end
  object qContInfo: TIBQuery
    Database = DMInv.DBRead
    Transaction = DMInv.IBTransaction1
    AfterInsert = qContInfoAfterInsert
    BeforeOpen = qContInfoBeforeOpen
    CachedUpdates = True
    SQL.Strings = (
      'SELECT CI.*, SD.SDNAME'
      'FROM CONTACTINFO CI'
      'INNER JOIN SYS_DIC SD ON SD.SDID = CI.CITYPE'
      'WHERE CI.PID = :PID and CI.citype = 1153')
    UpdateObject = quContInfo
    GeneratorField.Field = 'CIID'
    GeneratorField.Generator = 'GEN_CONTACTINFO'
    Left = 472
    Top = 704
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'PID'
        ParamType = ptUnknown
      end>
    object qContInfoCIID: TIntegerField
      FieldName = 'CIID'
      Origin = '"CONTACTINFO"."CIID"'
      ProviderFlags = [pfInUpdate, pfInWhere, pfInKey]
      Required = True
    end
    object qContInfoPID: TIntegerField
      FieldName = 'PID'
      Origin = '"CONTACTINFO"."PID"'
      Required = True
    end
    object qContInfoCITYPE: TIntegerField
      FieldName = 'CITYPE'
      Origin = '"CONTACTINFO"."CITYPE"'
    end
    object qContInfoCIVALUE: TIBStringField
      DisplayLabel = #1047#1085#1072#1095#1077#1085#1080#1077
      FieldName = 'CIVALUE'
      Origin = '"CONTACTINFO"."CIVALUE"'
      Size = 255
    end
    object qContInfoCINOTE: TIBStringField
      DisplayLabel = #1055#1088#1080#1084#1077#1095#1072#1085#1080#1077
      FieldName = 'CINOTE'
      Origin = '"CONTACTINFO"."CINOTE"'
      Size = 255
    end
    object qContInfoCIUSERENTER: TIBStringField
      DisplayLabel = #1044#1086#1073#1072#1074#1080#1083
      FieldName = 'CIUSERENTER'
      Origin = '"CONTACTINFO"."CIUSERENTER"'
      Size = 40
    end
    object qContInfoCITIMEENTER: TDateTimeField
      DisplayLabel = #1044#1086#1073#1072#1074#1083#1077#1085#1086
      FieldName = 'CITIMEENTER'
      Origin = '"CONTACTINFO"."CITIMEENTER"'
    end
    object qContInfoCIUSEREDIT: TIBStringField
      DisplayLabel = #1048#1079#1084#1077#1085#1080#1083
      FieldName = 'CIUSEREDIT'
      Origin = '"CONTACTINFO"."CIUSEREDIT"'
      Size = 40
    end
    object qContInfoCITIMEEDIT: TDateTimeField
      DisplayLabel = #1048#1079#1084#1077#1085#1077#1085#1086
      FieldName = 'CITIMEEDIT'
      Origin = '"CONTACTINFO"."CITIMEEDIT"'
    end
    object qContInfoSDNAME: TIBStringField
      DisplayLabel = #1053#1072#1079#1074#1072#1085#1080#1077
      FieldName = 'SDNAME'
      Origin = '"SYS_DIC"."SDNAME"'
      Size = 255
    end
  end
  object dsContInfo: TDataSource
    DataSet = qContInfo
    Left = 440
    Top = 704
  end
  object sqlInsertDovLitsa: TIBSQL
    Database = DMInv.DBRead
    SQL.Strings = (
      'UPDATE OR INSERT INTO DOV_LITSA (PID_POLUCH, PID, DLSTATUS)'
      'VALUES (:PID_POLUCH, :PID, :DLSTATUS)'
      'MATCHING(PID_POLUCH, PID)')
    Transaction = DMInv.IBTransaction1
    Left = 409
    Top = 305
  end
  object qCheckPeriodAgr: TIBQuery
    Database = DMInv.DBRead
    Transaction = DMInv.IBTransaction1
    SQL.Strings = (
      'SELECT a.AGID'
      'FROM AGREEMENTS A'
      'INNER JOIN AGR_POLUCH_USLUG apu ON apu.AGID = a.AGID'
      'WHERE apu.PID = :PID'
      'AND (a.AGDATEBEGIN <= :data2 AND a.AGDATEEND >= :data1)'
      'AND a.AGISDELETE IS NULL'
      'AND A.AGID <> :agid')
    Left = 554
    Top = 259
    ParamData = <
      item
        DataType = ftUnknown
        Name = 'PID'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data2'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'data1'
        ParamType = ptUnknown
      end
      item
        DataType = ftUnknown
        Name = 'agid'
        ParamType = ptUnknown
      end>
  end
end
